ARD2  1.00 for Rev B. Hardware
Airbag Reference Demonstrator using MPC5604P
CGM.c File Reference

Clock Generation Module. More...

#include "derivative.h"
#include "CGM.h"

Functions

void vfnClockOutputEnable (CGMCLKOutConfig_t tMyCGMConfig)
 Given that P[22] is enabled, this function enables or disables output of a clock signal to the CLKOUT pin.
uint8_t u8fnClockPLLConfig (uint8_t u8PLLInstance, uint8_t u8IDF, uint8_t u8ODF, uint8_t u8LDF)
 This function allows to configure a PLL setting in order to change the frequency of the system bus (or any other). It responds to the formula (Fosc * LDF) / (IDF * ODF).
void vfnClockClearPLLFlag (uint8_t u8PLLInstance)
 This function clears any existing PLL faults for a given instance.

Detailed Description

Clock Generation Module.

Copyright (c) 2011 Freescale Semiconductor Freescale Confidential Proprietary

Author:
Freescale Semiconductor
SASD Automotive
R11515
Version:
Date:
Warning:
(If needed)

History:


Function Documentation

uint8_t u8fnClockPLLConfig ( uint8_t  u8PLLInstance,
uint8_t  u8IDF,
uint8_t  u8ODF,
uint8_t  u8LDF 
)

This function allows to configure a PLL setting in order to change the frequency of the system bus (or any other). It responds to the formula (Fosc * LDF) / (IDF * ODF).

Parameters:
u8PLLInstance,:Either 0 or 1, depending on which PLL we're config u8IDF: IDF value in the formula. Can't be bigger than 4 bits. u8ODF: IDF value in the formula. Can't be bigger than 2 bits. u8LDF: IDF value in the formula. Can't be bigger than 7 bits.
Returns:
Clear if everything is in order; INVALID_PLL_INSTANCE if the passed instance is invalid; INVALID_PLL_DIVIDER if any of the passed arguments is outside of the valid values.
void vfnClockClearPLLFlag ( uint8_t  u8PLLInstance)

This function clears any existing PLL faults for a given instance.

Parameters:
u8PLLInstance,:Either 0 or 1, depending on which PLL we're config
Returns:
void.
void vfnClockOutputEnable ( CGMCLKOutConfig_t  tMyCGMConfig)

Given that P[22] is enabled, this function enables or disables output of a clock signal to the CLKOUT pin.

Parameters:
tMyCGMConfig,:Contains enable/disable information, as well as the divisor value (1, 2, 4, 8) and the source (IRC, XTAL, PLL0 or PLL1) as defined by CGMCLKOutConfig_t.
Returns:
void.